package com.qyhl.webtv.commonlib.entity.act;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.List;

/**
 * Created by qyhl2 on 2017/12/27.
 */

public class PlayerVOBean implements Parcelable {

    /**
     * 选手信息
     */
    private PlayerBean player;

    /**
     * 选手报名信息
     */
    private List<PlayerViewResultBean> results;

    /**
     * 选手当前票数
     */
    private Integer voteNumber;

    /**
     * 排名
     */
    private Integer ranking;


    private Integer applyCoverWidth;
    private Integer applyCoverHeight;

    /**
     * 作品集
     */
    private List<PlayerWorkVOBean> playerWorksList;



    private Integer isSelected = 0;

    public Integer getIsSelected() {
        return isSelected;
    }

    public void setIsSelected(Integer isSelected) {
        this.isSelected = isSelected;
    }

    public PlayerBean getPlayer() {
        return player;
    }

    public void setPlayer(PlayerBean player) {
        this.player = player;
    }

    public List<PlayerViewResultBean> getResults() {
        return results;
    }

    public void setResults(List<PlayerViewResultBean> results) {
        this.results = results;
    }

    public Integer getVoteNumber() {
        return voteNumber;
    }

    public void setVoteNumber(Integer voteNumber) {
        this.voteNumber = voteNumber;
    }

    public List<PlayerWorkVOBean> getPlayerWorksList() {
        return playerWorksList;
    }

    public Integer getRanking() {
        return ranking;
    }

    public void setRanking(Integer ranking) {
        this.ranking = ranking;
    }

    public Integer getApplyCoverWidth() {
        return applyCoverWidth;
    }

    public void setApplyCoverWidth(Integer applyCoverWidth) {
        this.applyCoverWidth = applyCoverWidth;
    }

    public Integer getApplyCoverHeight() {
        return applyCoverHeight;
    }

    public void setApplyCoverHeight(Integer applyCoverHeight) {
        this.applyCoverHeight = applyCoverHeight;
    }

    public void setPlayerWorksList(List<PlayerWorkVOBean> playerWorksList) {
        this.playerWorksList = playerWorksList;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeParcelable(this.player, flags);
        dest.writeTypedList(this.results);
        dest.writeValue(this.voteNumber);
        dest.writeTypedList(this.playerWorksList);
        dest.writeValue(this.isSelected);
    }

    public PlayerVOBean() {
    }

    protected PlayerVOBean(Parcel in) {
        this.player = in.readParcelable(PlayerBean.class.getClassLoader());
        this.results = in.createTypedArrayList(PlayerViewResultBean.CREATOR);
        this.voteNumber = (Integer) in.readValue(Integer.class.getClassLoader());
        this.playerWorksList = in.createTypedArrayList(PlayerWorkVOBean.CREATOR);
        this.isSelected = (Integer) in.readValue(Integer.class.getClassLoader());
    }

    public static final Parcelable.Creator<PlayerVOBean> CREATOR = new Parcelable.Creator<PlayerVOBean>() {
        @Override
        public PlayerVOBean createFromParcel(Parcel source) {
            return new PlayerVOBean(source);
        }

        @Override
        public PlayerVOBean[] newArray(int size) {
            return new PlayerVOBean[size];
        }
    };
}
